package com.hzncc.flowable_diboot.delivery.entity;

import java.time.LocalDate;
import java.time.LocalDateTime;
import java.util.Date;
import java.util.List;
import java.lang.Double;
import java.math.BigDecimal;
import jakarta.validation.constraints.NotNull;
import org.hibernate.validator.constraints.Length;


import com.diboot.core.util.D;
import com.diboot.core.entity.BaseModel;
import com.diboot.core.entity.BaseEntity;
import com.diboot.core.binding.query.BindQuery;
import com.diboot.core.binding.query.Comparison;

import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.FieldFill;
import com.baomidou.mybatisplus.extension.handlers.JacksonTypeHandler;

import lombok.Getter;
import lombok.Setter;
import lombok.experimental.Accessors;

/**
* 发货登记 Entity 定义
* @author MyName
* @version 1.0
* @date 2024-10-12
* Copyright © MyCorp
*/

@TableName("mdl_delivery_register")
@Getter @Setter @Accessors(chain = true)
public class DeliveryRegister extends BaseModel {
    private static final long serialVersionUID = 1380207490501915621L;

    /**
     * 租户
     */
    @NotNull(message = "租户不能为空")
    @TableField()
    private String tenantId;

    /**
     * 是否登记
     */
    @NotNull(message = "是否登记不能为空")
    @TableField()
    private String registered;

    /**
     * 登记类型
     */
    @TableField()
    private String registerType;

    /**
     * 合同评审类型
     */
    @Length(max=100, message="合同评审类型长度应小于100")
    @BindQuery(comparison = Comparison.LIKE)
    @TableField()
    private String reviewCategory;

    /**
     * 引用发货单号
     */
    @Length(max=100, message="引用发货单号长度应小于100")
    @BindQuery(comparison = Comparison.LIKE)
    @TableField()
    private String quoteDeliveryCode;

    /**
     * 引用非常规发货单号
     */
    @Length(max=100, message="引用非常规发货单号长度应小于100")
    @BindQuery(comparison = Comparison.LIKE)
    @TableField()
    private String quoteAbnormalCode;

    /**
     * 引用冲销发货单号
     */
    @Length(max=100, message="引用冲销发货单号长度应小于100")
    @BindQuery(comparison = Comparison.LIKE)
    @TableField()
    private String quoteReversalCode;

    /**
     * sap合同号
     */
    @Length(max=100, message="sap合同号长度应小于100")
    @BindQuery(comparison = Comparison.LIKE)
    @TableField()
    private String sapContractCode;

    /**
     * 销售订单号
     */
    @Length(max=100, message="销售订单号长度应小于100")
    @BindQuery(comparison = Comparison.LIKE)
    @TableField()
    private String sapOrderCode;

    /**
     * 发货单号
     */
    @Length(max=100, message="发货单号长度应小于100")
    @BindQuery(comparison = Comparison.LIKE)
    @TableField()
    private String deliveryCode;

    /**
     * 发货情况
     */
    @TableField()
    private String deliverySituation;

    /**
     * SAP发货日期
     */
    @TableField()
    private LocalDateTime sapDeliveryTime;

    /**
     * 实际发货时间
     */
    @TableField()
    private LocalDateTime deliveryTime;

    /**
     * 计划发货时间
     */
    @TableField()
    private LocalDateTime planDeliveryTime;

    /**
     * 发货是否延迟
     */
    @Length(max=100, message="发货是否延迟长度应小于100")
    @BindQuery(comparison = Comparison.LIKE)
    @TableField()
    private String delaied;

    /**
     * 发货延迟天数
     */
    @Length(max=100, message="发货延迟天数长度应小于100")
    @BindQuery(comparison = Comparison.LIKE)
    @TableField()
    private String delayDays;

    /**
     * 运输公司
     */
    @Length(max=100, message="运输公司长度应小于100")
    @BindQuery(comparison = Comparison.LIKE)
    @TableField()
    private String transitCompany;

    /**
     * 件数
     */
    @TableField()
    private Long quantity;

    /**
     * 重量
     */
    @TableField()
    private BigDecimal weight;

    /**
     * 成套性发货
     */
    @Length(max=100, message="成套性发货长度应小于100")
    @BindQuery(comparison = Comparison.LIKE)
    @TableField()
    private String completeSet;

    /**
     * 发货数量
     */
    @TableField()
    private BigDecimal deliveryQuantity;

    /**
     * 发货单价
     */
    @TableField()
    private BigDecimal deliveryPrice;

    /**
     * 发货金额
     */
    @TableField()
    private BigDecimal deliveryAmount;

    /**
     * 货单号
     */
    @Length(max=100, message="货单号长度应小于100")
    @BindQuery(comparison = Comparison.LIKE)
    @TableField()
    private String billCode;

    /**
     * 收货人
     */
    @Length(max=100, message="收货人长度应小于100")
    @BindQuery(comparison = Comparison.LIKE)
    @TableField()
    private String consigneeName;

    /**
     * 备注
     */
    @Length(max=100, message="备注长度应小于100")
    @BindQuery(comparison = Comparison.LIKE)
    @TableField()
    private String remark;

    /**
     * 是否已开票
     */
    @TableField()
    private String invoiced;

    /**
     * 开票时间
     */
    @TableField()
    private LocalDateTime invoiceTime;

    /**
     * 未开票类型
     */
    @TableField()
    private String invoiceType;

    /**
     * 预计开票时间
     */
    @TableField()
    private LocalDateTime planInvoiceTime;

    /**
     * 未开票原因
     */
    @Length(max=100, message="未开票原因长度应小于100")
    @BindQuery(comparison = Comparison.LIKE)
    @TableField()
    private String invoiceReason;


}